package com.ist412.pocke;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.Window;
import android.view.WindowManager;
import android.widget.ArrayAdapter;
import android.widget.ImageView;
import android.widget.ListView;

/**
 * @author Rob C
 * @version 1.0
 */
public class AboutActivity extends Activity implements OnClickListener {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		
		// Remove title & Make fullscreen
        requestWindowFeature(Window.FEATURE_NO_TITLE);
        getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
        WindowManager.LayoutParams.FLAG_FULLSCREEN);
		
		setContentView(R.layout.activity_about);
		
		ListView lvwPeople = (ListView) findViewById(R.id.about_lvwPeople);
		String[] people = getResources().getStringArray(R.array.aboutpeople);
		ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, R.layout.spinner_item, people);
		lvwPeople.setAdapter(adapter);
		
		ImageView imgBack = (ImageView) findViewById(R.id.about_imgBack);
		
		imgBack.setOnClickListener(this);
		
		
	} // end override onCreate
	
	
	@Override
	public void onClick(View v) {
		switch (v.getId()) {
			case R.id.about_imgBack:
				finish();
				break;
		}
	} // end override onClick
	
} // end class AboutActivity